package com.dropdb.demo.service;

import com.dropdb.demo.bean.*;
import com.dropdb.demo.bean.bo.AdminListGoodsBO;
import com.dropdb.demo.bean.enumeration.ErrorReason;
import com.dropdb.demo.bean.vo.AdminCateAndBrandVO;
import com.dropdb.demo.bean.vo.BaseData;

import java.util.Date;
import java.util.List;

public interface GoodsService {
    BaseData ListGoods(AdminListGoodsBO listGoodsBO);


    AdminCateAndBrandVO ListCateAndBrand();

    ErrorReason addGoods(AdminGoodsPOJO addGoodsBO);

    AdminGoodsPOJO getGoodsDetailById(Integer id);

    ErrorReason updateGoods(AdminGoodsPOJO updateGoodsBO);

    void deleteGoods(Goods goods);

    void insertProduct(Date date, Integer goodsId, GoodsProduct product);

    void insertAttribute(Date date, Integer goodsId, GoodsAttribute attribute);

    void insertSpecification(Date date, Integer goodsId, GoodsSpecification specification);

    List<GoodsSpecification> getGoodsSpecifications(Integer id);

    List<GoodsProduct> getGoodsProducts(Integer id);

    List<GoodsAttribute> getGoodsAttributes(Integer id);

    ErrorReason isHasSameGoodsByNameOrGoodSn(Goods goods);


}
